<?php
define('MODULE_NAME','goods');
$actions = array('index','search','show','go');
$action = 'index';

if(isset($_REQUEST['action']))
{
	$action = strtolower($_REQUEST['action']);
	if(!in_array($action,$actions))
		$action = 'index';
}
	
define('ACTION_NAME',$action);

if(in_array(ACTION_NAME,array('index','search')))
	define('IS_EXPIRED',1);

require_once './core/service/fanwe.service.php';
$fanwe = &FanweService::instance();
if(ACTION_NAME == 'go')
	$fanwe->is_user = false;

$fanwe->cache_list[] = 'site';
$fanwe->is_group_city = true;
$fanwe->initialize();

require import('module/goods');

switch(ACTION_NAME)
{
	case 'index':
		GoodsModule::index();
	break;
	case 'search':
		GoodsModule::search();
	break;
	case 'show':
		GoodsModule::show();
	break;
	case 'go':
		GoodsModule::go();
	break;
}
?>